package com.hgshop.yudongyang.service.impl;



import javax.annotation.Resource;

import org.apache.dubbo.config.annotation.Service;

import com.github.pagehelper.PageHelper;
import com.github.pagehelper.PageInfo;
import com.hgshop.yudongyang.dao.BrandMapper;
import com.hgshop.yudongyang.domain.Brand;

import com.hgshop.yudongyang.service.BrandService;
@Service
public class BrandServiceImpl implements BrandService {

	@Resource
	BrandMapper brandMapper;
	@Override
	public PageInfo<Brand> list(int pageNum, int pageSize) {
		// TODO Auto-generated method stub
		PageHelper.startPage(pageNum, pageSize);
		return new PageInfo<Brand>(brandMapper.list());
	}
	@Override
	public int add(Brand brand) {
		// TODO Auto-generated method stub
		
		return brandMapper.addBrand(brand);
	}
	

}
